import 'package:flutter/material.dart';
import 'package:study_flutter/views/form.dart';
import 'package:study_flutter/views/home.dart';
import 'package:study_flutter/views/state_ful_widget.dart';
import 'package:study_flutter/views/state_less_widget.dart';
import 'package:study_flutter/views/text.dart';

void main() {
  runApp(const MyApp());
}

final routes = <String, WidgetBuilder>{
  "/": (BuildContext context) => const HomeWidget(),
  "/form": (BuildContext context) => const FormWidget(),
  "/stateLessWidget": (BuildContext context) => const CustomStateLessWidget(),
  '/statefulWidget': (BuildContext context) => const CustomStatefulWidget(),
  '/text': (BuildContext context) => const TextWidget()
};

class MyApp extends StatelessWidget {
  const MyApp({super.key});
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      routes: routes,
    );
  }
}
